{include file="Public:header" /}
{include file="Public:nav" /}

<div class="bar bar-nav">
    <div class="user_tab text-center buttons-row">
        <a class="tab-link button button-round active" href="#tabs_1">参与者</a>
        <a class="tab-link button button-round" href="#tabs_2">主办方</a>
    </div>
    <i class="icon icon-left" onclick="window.history.go(-1);"></i>
    <a href="{:U('message')}"><i class="icon icon-message pull-right" style="color: #0894ec;font-weight: bold;">
        {$message_count|default="0"}</i></a>

</div>
<div class="content">
    <div class="row">

        <div class="col-100">
            <div class="user_top">
                <div class="user_img pull-left">
                    <img src="{$Think.session.headimgurl}">
                </div>
                <a href="{:U('usersDetail')}">
                    <span class="pull-right icon icon-right"></span>
                </a>
                <div class="user_text">
                    <h3>{$Think.session.nickname}</h3>
                    <p><span>[ {switch name="users['user_type']"}
										    {case value="1"}游客 {/case}
										    {case value="2"}正式会员{/case}
										    {case value="3"}副会长{/case}
										    {case value="4"}理事{/case}
										    {case value="5"}国旗文化{/case}
										    {case value="6"}军事运动{/case}
										    {case value="7"}国防传媒{/case}
										    {case value="8"}军事警觉{/case}
										 {/switch} ]
                                                                                 {if condition="$users['expert_type']"}
										 &nbsp;[
                                                                                 {switch name="users['expert_type']"}
										    {case value="1"}军事专家 {/case}
										    {case value="2"}国防专家{/case}
										    {case value="3"}医学专家{/case}
										 {/switch}&nbsp;]
                                                                                 {/if}
							 </span>
                    </p>

                </div>
            </div>
        </div>
        <div class="col-100 tabs" style="margin-top:.5rem;">
            <div class="user_txt tab active" id="tabs_1">
                <div class="user_order">
                    <div class="user_order_title">
                        我的订单<span class="pull-right open-indicator"><a href="{:U('my_order')}">全部订单</a><i
                            class="icon icon-right"></i></span>
                    </div>
                    <div class="user_order_txt">
                        <ul>
                            <li><a href="{:U('my_order')}"><span>{$order_count[0]}</span>
                                <p>待付款</p></a></li>
                            <li><a href="{:U('my_order')}"><span>{$order_count[1]}</span>
                                <p>待参与</p></a></li>
                            <li><a href="{:U('my_order')}"><span>{$order_count[2]}</span>
                                <p>己完成</p></a></li>
                        </ul>
                    </div>
                </div>
                <div class="user_list list-block">
                    <ul>
                        <li>
                            <a href="{:U('collect')}" class="item-link item-content">
                                <div class="item-media"><i class="icon iconfont icon-favorite"></i></div>
                                <div class="item-inner">
                                    <div class="item-title open-indicator">我的关注</div>
                                </div>
                            </a>
                        </li>
                        <li>
                            <a href="#" class="item-link item-content">
                                <div class="item-media"><i class="icon iconfont icon-gifts"></i></div>
                                <div class="item-inner">
                                    <div class="item-title">我的奖品</div>
                                </div>
                            </a>
                        </li>
                        <li>
                            <a href="answer.html#router3" class="item-link item-content">
                                <div class="item-media"><i class="icon iconfont icon-mingcheng"></i></div>
                                <div class="item-inner">
                                    <div class="item-title">我的成绩</div>
                                </div>
                            </a>
                        </li>
                        <!--						         <li>
                                                            <a href="user_expert_yuyue.html" class="item-link item-content">
                                                              <div class="item-media"><i class="icon iconfont icon-add"></i></div>
                                                              <div class="item-inner">
                                                                <div class="item-title">发布预约</div>
                                                              </div>
                                                            </a>
                                                         </li>-->
                        <li>
                            <a href="{:U('Apply/expert_discuss')}" class="item-link item-content">
                                <div class="item-media"><i class="icon iconfont icon-clock"></i></div>
                                <div class="item-inner">
                                    <div class="item-title">我的预约</div>
                                </div>
                            </a>
                        </li>
                        {if condition="$is_apply"}
                        <li>
                            <a href="{:U('my_apply')}" class="item-link item-content">
                                <div class="item-media"><i class="icon iconfont icon-edit"></i></div>
                                <div class="item-inner">
                                    <div class="item-title">会员申请
                                        &nbsp;{if condition="$shwo_apply_message"}<i
                                                class="icon icon-message pull-right"
                                                style="color: #0894ec;font-weight: bold;"></i>{/if}
                                    </div>

                                </div>
                            </a>
                        </li>
                        {/if}
                        <li>
                            <a href="{:U('Apply/expert_join')}" class="item-link item-content">
                                <div class="item-media"><i class="icon iconfont icon-edit"></i></div>
                                <div class="item-inner">
                                    <div class="item-title">专家申请</div>
                                </div>
                            </a>
                        </li>
                        <!-- <li>
                          <a href="{:U('addSweep')}" class="item-link item-content">
                            <div class="item-media"><i class="icon icon-code"></i></div>
                            <div class="item-inner">
                              <div class="item-title">添加扫码
                              </div>
                            </div>
                          </a>
                       </li>-->
                    </ul>
                </div>
            </div>
            <div class="user_txt tab" id="tabs_2">
                <div class="user_order">
                    <div class="user_order_txt user_cbf">
                        <ul>
                            <li><a href="{:U('Users/releaseActivity')}"><span class="iconfont icon-fenxiang"></span>
                                <p>发布活动</p></a></li>
                            <li><a href="{:U('Users/activity_administration')}"><span class="iconfont icon-edit"></span>
                                <p>活动管理</p></a></li>
                            <li><a href="{:U('addSweep')}"><span class="iconfont icon-mingcheng"></span>
                                <p>添加扫码</p></a></li>
                            <li><a href="{:U('Users/user_expert_yuyue')}"><span class="iconfont icon-fenxiang"
                                                                                style="color: #65a7f2;"></span>
                                <p>发布预约</p></a></li>
                            <li><a href="{:U('Users/user_apply_order')}"><span class="iconfont icon-edit"
                                                                               style="color: #85da38"></span>
                                <p>预约管理</p></a></li>
                            <li><a href="{:U('Apply/expert_join')}"><span class="iconfont icon-mingcheng"
                                                                          style="color: #ea68a2"></span>
                                <p>专家申请</p></a></li>
                        </ul>
                    </div>
                </div>

                <div class="in_hot_box activity_1" id="new_ul">
                    <div class="card-title">最新活动</div>
                    {foreach name="new" item="new" key="k"}
                    <div class="card demo-card-header-pic">
                        <a href="/ActivityDetail/index?activity_id={$new['id']}&city={$new['city']}">
                            <div valign="bottom" class="card-header color-white no-border no-padding">
                                <img class='card-cover' src="{$new['activity_img']}" alt="">
                            </div>
                            <div class="card-content">
                                <div class="card-content-inner">
                                    <p class="hot_list_title">{$new['activity_name']}</p>
                                    <p class="color-gray">{$new['start_time']|date="Y-m-d",###} 至
                                        {$new['end_time']|date="Y-m-d",###}</p>
                                    <p class="color-gray">
                                        <span>{$new['area']}</span><span>{$new['signup_number']}人已报名</span><span>￥{$new['price']}</span>
                                    </p>
                                </div>
                            </div>
                        </a>
                    </div>
                    {/foreach}
                </div>
                {if condition="$new_activity"}
                <div class="infinite-scroll-preloader" style="display:none;">
                    <div class="preloader"></div>
                </div>
                <p onclick="ajax_sourch_submit();" id="load_more"><span class="icon icon-down"></span> 点击加载更多...</p>
                {else/}
                <p id="load_more"> 暂无数据！</p>
                {/if}
            </div>
        </div>
    </div>
</div>
{include file="Public:footer" /}

<script>
    //Zepto.toast('操作成功，正在跳转...', 2000, 'success top');
    var page = 1;
    /*** ajax 提交表单 查询订单列表结果*/
    function ajax_sourch_submit() {
        $(".infinite-scroll-preloader").show();
        page += 1;
        $.ajax({
            type: "GET",
            //url:"/index.php?m=Mobile&c=User&a=collect_list&is_ajax=1&p="+page,//+tab,
            url: "/Users/newActivity/is_ajax/1/p/" + page,//+tab,
//			data : $('#filter_form').serialize(),// 你的formid 搜索表单 序列化提交
            success: function (data) {
                $(".infinite-scroll-preloader").hide();
                if ($.trim(data) == '') {
                    $('#load_more').hide();
                } else {
                    $("#new_ul").append(data);
                }
            }
        });
    }
</script>